<!doctype html>
<html lang="en">

	<head>
		<!-- Meta -->
		<meta charset="UTF-8">
		<meta name="viewport" content="width=device-width, initial-scale=1.0">
		<meta http-equiv="X-UA-Compatible" content="ie=edge">

		<!-- favicon -->
		<link rel="icon" sizes="16x16" href="assets/img/favicon1.ico">

		<!-- Title -->
		<title> ASLife 生活分享平台 </title>

		<!-- Font Google -->
		<link href="https://fonts.googleapis.com/css?family=Muli:300,400,500,600,700,800,900&display=swap"
			rel="stylesheet">

		<!-- CSS Plugins -->
		<link rel="stylesheet" href="assets/css/all.css">
		<link rel="stylesheet" href="assets/css/elegant-font-icons.css">
		<link rel="stylesheet" href="assets/css/bootstrap.min.css">
		<link rel="stylesheet" href="assets/css/owl.carousel.css">
		<!-- main style -->
		<link rel="stylesheet" href="assets/css/style.css">

	</head>

	<body>
		<!--loading -->
		<div class="loading">
			<div class="circle"></div>
		</div>
		<!--/-->

		<!-- Navigation-->
		<nav class="navbar navbar-expand-lg fixed-top">
			<div class="container-fluid">
				<!--logo-->
				<div class="logo">
					<a href="index.html">
						<img src="assets/img/aslife-logo.png" alt="">
					</a>
				</div>
				<!--/-->

				<!--navbar-collapse-->
				<div class="collapse navbar-collapse" id="main_nav">
					<ul class="navbar-nav ml-auto mr-auto">
						<li class="nav-item ">
							<a class="nav-link " href="index.html"> 首页 </a>

						</li>


						<li class="nav-item ">
							<a class="nav-link  " href="find.html"> 发现 </a>

						</li>
						<!-- <li class="nav-item dropdown">
                        <a class="nav-link  dropdown-toggle" href="post-default.html" data-toggle="dropdown"> Posts Features </a>
                        <ul class="dropdown-menu fade-up">
                            <li>
                                <a class="dropdown-item" href="post-default.html"> post default</a>
                            </li>
                            <li>
                                <a class="dropdown-item" href="post-no-sidebar.html"> post no sidebar </a>
                            </li>
                            <li>
                                <a class="dropdown-item" href="post-left-sidebar.html"> post left sidebar </a>
                            </li>
                        </ul>
                    </li> -->

						<li class="nav-item">
							<a class="nav-link" href="about.html"> About </a>
						</li>
						<li class="nav-item">
							<a class="nav-link" href="publish.html"> 发表 </a>
						</li>


					</ul>
				</div>
				<!--/-->

				<!--navbar-right-->
				<div class="navbar-right ml-auto">
					<div class="social-icones">
						<ul class="list-inline">



							<a href="login.html">
								<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor"
									class="bi bi-person-circle" viewBox="0 0 16 16">
									<path d="M11 6a3 3 0 1 1-6 0 3 3 0 0 1 6 0z" />
									<path fill-rule="evenodd"
										d="M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8zm8-7a7 7 0 0 0-5.468 11.37C3.242 11.226 4.805 10 8 10s4.757 1.225 5.468 2.37A7 7 0 0 0 8 1z" />
								</svg>
							</a>


							<a href="index.html">
								<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor"
									class="bi bi-chat-square-text-fill" viewBox="0 0 16 16">
									<path
										d="M0 2a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2h-2.5a1 1 0 0 0-.8.4l-1.9 2.533a1 1 0 0 1-1.6 0L5.3 12.4a1 1 0 0 0-.8-.4H2a2 2 0 0 1-2-2V2zm3.5 1a.5.5 0 0 0 0 1h9a.5.5 0 0 0 0-1h-9zm0 2.5a.5.5 0 0 0 0 1h9a.5.5 0 0 0 0-1h-9zm0 2.5a.5.5 0 0 0 0 1h5a.5.5 0 0 0 0-1h-5z" />
								</svg>
							</a>


						</ul>
					</div>

					<div class="search-icon">
						<i class="icon_search"></i>
					</div>

					<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#main_nav"
						aria-expanded="false" aria-label="Toggle navigation">
						<span class="navbar-toggler-icon"></span>
					</button>
				</div>
			</div>
		</nav>
		<!--/-->



		<!--grid-layout-->
		<section class="section pt-85">
			<div class="container-fluid">
				<div class="row">


				</div>
			</div>
		</section>
		<!--/-->


		<!--Search-->
		<div class="search">
			<div class="container-fluid">
				<div class="row">
					<div class="col-lg-6 offset-lg-3 col-md-8 offset-md-2 col-sm-10 offset-sm-1 text-center">
						<button type="button" class="close">
							<i class="icon_close"></i>
						</button>
						<form class="search-form" action="#">
							<input type="search" value="" placeholder="What are you looking for?">
							<button type="submit" class="search-btn">search</button>
						</form>
					</div>
				</div>
			</div>
		</div>
		<!--/-->

		<script src="https://lib.sinaapp.com/js/jquery/2.0.2/jquery-2.0.2.min.js"></script>
		<script src="assets/js/script.js"></script>

		<script type="text/javascript">
			$(document).ready(function() {

				//初始加载调用一次
				getData();

				function getData() {

					//jQuery封装的方法
					$.ajax({

						url: "http://localhost:8080/api/article/list",
						async: true,
						dataType: "json",
						type: "get",
						// 请求成功后，服务端正常响应的回调函数
						success: function(responsedata) {

							let list = responsedata.rows;
							for (let s of list) {
								let str = `
					<div class="col-lg-4 col-md-6">					
                    <!--Post-1-->
                    <div class="post-card">
                        <div class="post-card-image">
                            <a href="article_info.html?${s.aid}">
                                <img src="https://as-soul.oss-cn-hangzhou.aliyuncs.com/article-img/${s.img}" alt="">
								
                            </a>
                        </div>
                        <div class="post-card-content">
                            <a href="blog-grid.html" class="categorie">Livestyle</a>
                            <h5>
                                <a href="article_info.html?${s.aid}">${s.title}</a>
                            </h5>
                            <p>${s.text}</p>
                            <div class="post-card-info">
                                <ul class="list-inline">
                                    <li>
                                        <a href="author.html?${s.uid}">
                                            <img src="assets/img/author/1.jpg" alt="">
                                        </a>
                                    </li>
                                    <li>
                                                 ${s.aid}
                                    </li>
                                    <li class="dot"></li>
                                    <li>点赞数：${s.goods}</li>
                                </ul>
                            </div>
                        </div>
                    </div>
                    <!--/-->
                </div>`;
								$(".row").append(str);
							}

							// resolvepage();
						}

					});
				}
			});
		</script>



		<!-- jQuery first, then Popper.js, then Bootstrap JS -->
		<script src="assets/js/jquery-3.5.0.min.js"></script>
		<script src="assets/js/popper.min.js"></script>
		<script src="assets/js/bootstrap.min.js"></script>

		<!-- JS Plugins  -->
		<script src="assets/js/ajax-contact.js"></script>
		<script src="assets/js/owl.carousel.min.js"></script>
		<script src="assets/js/main.js"></script>


	</body>

</html>
